package com.smwsk.activitiproject.service;

import org.activiti.engine.delegate.DelegateExecution;
import org.activiti.engine.runtime.Execution;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

@Component(value = "myProcessService")
public class MyProcessService {

    Logger logger = LoggerFactory.getLogger(this.getClass());
    /**
     * 自动通过审核
     * @param execution
     */
    public void autoPassAudit(DelegateExecution execution) throws Exception{
        String type = execution.getVariable("type").toString();
        logger.info("自动通过审核, 参数值type:{}", type);
    }

}
